package com.sskj.mine.ui.activity;


import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;

import com.alibaba.android.arouter.facade.annotation.Route;
import com.sskj.common.base.App;
import com.sskj.lib.RConfig;
import com.sskj.lib.base.BaseActivity;
import com.sskj.lib.util.APKVersionCodeUtils;
import com.sskj.mine.R;
import com.sskj.mine.R2;
import com.sskj.mine.presenter.MineUsActivityPresenter;

import butterknife.BindView;

@Route(path = RConfig.MINE_US)
public class MineUsActivity extends BaseActivity<MineUsActivityPresenter> {
    @BindView(R2.id.tvTitle)
    TextView tvTitle;
    @BindView(R2.id.left_img)
    ImageView leftImg;
    @BindView(R2.id.left_tv)
    TextView leftTv;
    @BindView(R2.id.ivBack)
    LinearLayout ivBack;
    @BindView(R2.id.right_tv)
    TextView rightTv;
    @BindView(R2.id.ivRight)
    ImageView ivRight;
    @BindView(R2.id.mine_email)
    TextView mineEmail;
    @BindView(R2.id.version)
    TextView version;

    @Override
    protected int getLayoutId() {
        return R.layout.activity_mine_us;
    }

    @Override
    public MineUsActivityPresenter getPresenter() {
        return new MineUsActivityPresenter();
    }

    @Override
    protected void initView() {
        super.initView();
        tvTitle.setText(App.INSTANCE.getString(R.string.mine_mineUsActivity1_j));
        version.setText(App.INSTANCE.getString(R.string.mine_mineUsActivity2_j) + APKVersionCodeUtils.getVerName(this));
    }

    @Override
    protected void initData() {
        super.initData();
        mPresenter.getEmailShop();
    }

    public void updateUi(String emial) {
        mineEmail.setText(emial);
    }
}
